
varying vec2 vUv;
varying float vAngle;

uniform float uRepeat;
uniform vec3 uCenterPosition;

void main(){
    //传递uv到片元着色器
    vUv = uv * vec2(uRepeat * 2.0, uRepeat);
    // float a = pow(position.x, 2.0);
    float a = position.y;
    float b = sqrt(pow(position.x, 2.0) + pow(position.z, 2.0));
    //vAngle从上往下范围为[1,-1]
    vAngle = atan(a / b) / 3.1416;
    gl_Position = projectionMatrix * modelViewMatrix * vec4( position , 1.0);
}